<template>
  <div class="header">
    <div class="title">vue-demo</div>
    <div class="userinfo">
      <el-button type="text" @click="loginOut">退出</el-button>
    </div>
  </div>
</template>
<script>
export default {
  name: "Header",
  data() {
    return {};
  },
  mounted() {},
  methods: {
    loginOut() {
      this.$router.push({ path: "/login" });
    }
  }
};
</script>
<style scoped>
.header {
  height: 60px;
  width: 100%;
  background-color: aqua;
}
.title {
  float: left;
  margin-left: 50px;
  height: 60px;
  line-height: 60px;
  width: 500px;
  font-size: 40px;
  text-align: left;
}
.userinfo {
  float: right;
  width: 300px;
  height: 60px;
  line-height: 60px;
}
</style>